package com.dongdongshop.service.impl;

import com.dongdongshop.domain.dto.TbGoodsDescDTO;
import com.dongdongshop.domain.model.TbGoodsDesc;
import com.dongdongshop.domain.model.TbGoodsDescExample;
import com.dongdongshop.mapper.TbGoodsDescMapper;
import com.dongdongshop.service.GoodsDescService;
import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class GoodsDescServiceImpl implements GoodsDescService {
    @Autowired
    private TbGoodsDescMapper goodsDescMapper;
    //添加商品明细表信息
    @Override
    public void addGoods(TbGoodsDescDTO goodsDescDTO) {
        TbGoodsDesc goodsDesc = new TbGoodsDesc();
        BeanUtils.copyProperties(goodsDescDTO,goodsDesc);
        goodsDescMapper.insertSelective(goodsDesc);
    }
}
